Skip to content

Enforce rustfmt: format src-tauri + add cargo fmt --check to CI#12

Merged
resure merged 3 commits into
mainfrom
claude/jovial-varahamihira-e27fd6
Jul 6, 2026
Merged

Enforce rustfmt: format src-tauri + add cargo fmt --check to CI#12
resure merged 3 commits into
mainfrom
claude/jovial-varahamihira-e27fd6

Conversation

@resure

@resure resure commented Jul 6, 2026

Copy link
Copy Markdown
Owner

What

Two commits, kept separate so the mechanical diff doesn't obscure the CI change:

  1. style: cargo fmt src-tauri — formatting-only. cargo fmt --check was dirty on main (drift in build.rs, the collect_md area of src/lib.rs, and src/main.rs). No code changes — 108 insertions / 44 deletions, all line-wrapping/indentation.
  2. ci: enforce cargo fmt --check in the rust job — adds cargo fmt --manifest-path src-tauri/Cargo.toml --check to the rust job and requests rustfmt in the toolchain components (dtolnay's action only installs what's listed). Placed first in the cargo-step block, above test/clippy, so a formatting failure surfaces in seconds instead of after the full crate compile.

Why

CI runs clippy but never checked formatting, so drift accumulated silently. This clears the existing drift and makes CI catch any new drift.

Verification

  • cargo fmt --check clean after formatting (verified with the exact CI invocation from the repo root).
  • cargo test: 23 passed, 0 failed after formatting.

🤖 Generated with Claude Code

resure and others added 3 commits July 6, 2026 17:32
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Runs before test/clippy so a formatting failure surfaces in seconds
instead of after the full crate compile.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Pre-existing violation on main (from a todo-update commit) that fails
`prettier --check .` in the verify job — unrelated to the Rust changes
here, but it blocks this PR's CI. Formatting-only, one line.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@resure resure merged commit c1c0a16 into main Jul 6, 2026
2 checks passed
@resure resure deleted the claude/jovial-varahamihira-e27fd6 branch July 6, 2026 15:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant